## Main.py
## Jeremy Keczan
## World of Fantast
## reference.py


import wx

class mainframe(wx.Frame):
    
    #must create a constructor function
    def __init__(self,parent,id):
        
        wx.Frame.__init__(self,parent,id,'World Of Fantast',size=(800,600))                         #default constructor
        panel=wx.Panel(self)                                                                        #create a panel
        button=wx.Button(panel,label="Exit",pos=(130,10),size=(60,60))                              
        self.Bind(wx.EVT_BUTTON,self.closebutton,button)
        self.Bind(wx.EVT_CLOSE,self.closemainframe)
        
        ##------------------------------------------------------------------------------------------------##
        ## Create menu bar
#        status = self.CreateStatusBar()
#        menubar = wx.MenuBar()
#        
#        first =wx.Menu()
#        second = wx.Menu()
#        
#        first.Append(wx.NewId(),"New Window","This is a new window")
#        first.Append(wx.NewId(),"Open...","This will open a new window")
#        
#        menubar.Append(first,"File")
#        menubar.Append(second,"Edit")
#        
#        self.SetMenuBar(menubar)
         ##Create a slider        
#        slider=wx.Slider(panel,-1,50,1,100,pos=(75,200),size=(250,-1),style=wx.SL_AUTOTICKS | wx.SL_LABELS)
#        slider.SetTickFreq(5,1)
        
         ## Create a single choice list
#        mylist = ['beef','tuna','concuts','beer','cereal','milk']
#        container = wx.ListBox(panel,-1,(20,20),(80,60),mylist,wx.LB_SINGLE)
#        container.SetSelection(3)
        
         ## Create checkboxes
#        wx.CheckBox(panel,-1,"Beer",(100,100), (160,-1))
#        wx.CheckBox(panel,-1,"wine",(100,120), (160,-1))

         ## Create Spinners
#        spinner = wx.SpinCtrl(panel,-1,"",(90,350), (90,-1))
#        spinner.SetRange(1,100)
#        spinner.SetValue(10)

        ##--------------------------------------------------------------------------------------------------##
        ##--------------------------------------------------------------------------------------------------##
        ## Create text entry boxes and static text, or normal text on screen
#        box=wx.TextEntryDialog(None,"Whats ur name?","Title","default")
#        
#        test=wx.TextEntryDialog(None,"Whats Your Name?","name",'enter name')
#        if test.ShowModal()==wx.ID_OK:
#            apples=test.GetValue()
#        
#        wx.StaticText(panel,-1,apples,(200,200))
#        pic = wx.Image("test.bmp",wx.BITMAP_TYPE_BMP).ConvertToBitmap()
#        self.button = wx.BitmapButton(panel,-1,pic,pos=(500,100))
#        self.Bind(wx.EVT_BUTTON,self.closemainframe,self.button)
#        self.button.SetDefault()
#
#        wx.StaticText(panel,-1, "This is static text",(10,10))
#        custom=wx.StaticText(panel,-1,"This is custom",(400,400),(260,-1),wx.ALIGN_CENTER)
#        custom.SetForegroundColour('green')
#        custom.SetBackgroundColour('white')
#        list=wx.SingleChoiceDialog(None,'Whats your fav food',"Food",['Tuna','Beef','Sausage'])
#        if list.ShowModal()==wx.ID_OK:
#            answer = list.GetStringSelection()
        
#        if box.ShowModal()==wx.ID_OK:
#            answer = box.GetValue()
#        box = wx.MessageDialog(None,"Agree to Terms",'Terms',wx.YES_NO)
#        termanswer = box.ShowModal()
#        box.Destroy()

        
    def closebutton(self, event):
        self.Close(True)
    
    def closemainframe(self,event):
        self.Destroy()
        
if __name__=='__main__':
    app=wx.PySimpleApp()
    frame = mainframe(parent=None, id=-1)
    frame.Show()
    app.MainLoop()